<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
</head>
<body>
  <div id='box1'>qwer</div>
  <p class="font">1</p>
  <p class="font">2</p>
  <p name="heihei">3</p>
  <script>
    console.log(document.getElementById('box1'))
    console.log(document.getElementsByClassName("font"))
    console.log(document.getElementsByName("heihei"))
    console.log(document.getElementsByTagName("p"))
    
  </script>
</body>
</html>